package com.ule.merchant.order.mon.service.kafka.handler;

import com.ule.tools.client.kafka.consumer.handler.AbstractConsumerHandler;
import kafka.utils.VerifiableProperties;
import lombok.extern.slf4j.Slf4j;

/**
  * 接收kafka消息接口
 */
@Slf4j
public class KafkaTestHandler extends AbstractConsumerHandler<String> {

	public KafkaTestHandler(VerifiableProperties props) {
		super(props);
	}

	public void handle(String key, String message) {
		log.info("[KafkaTestHandler:handle][INVOKE]param message：{}",message);
		long start = System.currentTimeMillis();
		try {
			//处理实际业务

		} catch (Exception e) {
			log.error("[KafkaTestHandler:handle]error consumer wait ship order from ule", e);
		}
		long end = System.currentTimeMillis();
		log.info("[KafkaTestHandler:handle][END]cost:{}",(end - start));
	}
	
}
